package cn.bdqn.pn.reposity.user;

import cn.bdqn.pn.pojo.order.MainOrder;
import cn.bdqn.pn.pojo.user.User;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;

import java.util.List;

public interface UserDao extends JpaRepository<User,Integer>, JpaSpecificationExecutor<User>{

    /**
     * 今日新增会员数
     * a是当前时间
     */
    @Query(value = "SELECT COUNT(1)  FROM USER WHERE registTime BETWEEN ?1 AND SYSDATE()",nativeQuery = true)
    Integer VIPByToday(String dangqian);


}
